/**
 * Copyright (C) 2011 Denatics Development
 *
 * Programmed by David Tiersch <dtiersch@denatics.com>
 *
 * This file is part of B0mberman.
 *
 * B0mberman is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * B0mberman is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with B0mberman. If not, see <http://www.gnu.org/licenses/>.
 */
package com.denatics.bomberman;

/**
 * In this list are the settings, which additional features are enabled.
 *
 * @author David Tiersch <dtiersch@denatics.com>
 */
public enum Features {
    /**
     * Enables Portals. Default: On
     */
    PORTALS(true);

    /**
     * Enabled-Switch.
     */
    private boolean enable;

    /**
     * Creates the Object for the Feature with given start state.
     *
     * @param state
     *            enabled
     */
    private Features(final boolean state) {
        this.enable = state;
    }

    /**
     * Returns if the Feature is enabled.
     *
     * @return if the Feature is enabled
     */
    public final boolean enabled() {
        return this.enable;
    }

    /**
     * Changes whether the Feature is enabled or disabled.
     *
     * @param newState
     *            New State.
     */
    public final void setEnabled(final boolean newState) {
        this.enable = newState;
    }
}
